package com.bank.model.vo.loan;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.web.multipart.MultipartFile;

import java.util.Date;

/**
 * @author Cejay1314
 * @version 1.0
 * @create 2023/3/29 11:56
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class LoanVo {
    @JsonSerialize(using= ToStringSerializer.class)
    Long id;
    @JsonSerialize(using=ToStringSerializer.class)
    Long borrowId;
    @JsonSerialize(using=ToStringSerializer.class)
    Long approverId;
    String status;
    String type;
    Double totalMoney;
    Double paidMoney;
    Double interestRate;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")  // 返回给前端的时候进行格式化
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") // 前端转递过来的时候进行格式化
    Date createdTime;
}
